import { createStore, combineReducers, applyMiddleware } from 'redux'
// combineReducers 合并reducer
import num from './reducer/num'
import count from './reducer/count'
let reducer = combineReducers({
    num,
    count
})
let store = createStore(reducer, applyMiddleware())

export default store

// let reducer = (state, action) => {
//     return {
//         num: num(state.num, action),
//         count: count(state.count, action)
//     }
// } 